<!DOCTYPE HTML PUBLIC "-//W3C//DTD HTML 3.2 Final//EN">
<HTML>
<HEAD>
<META HTTP-EQUIV="Content-Type" Content="text-html; charset=Windows-1252">
<title>TCard</title>
<style>@import url(coUA.css);</style>
<link disabled rel="stylesheet" href="htmlhelp.css">
</HEAD>

<BODY>
<h1><a name="ocx_tcard"></a>TCard command</h1>

<h2>Purpose</h2>

<p>Sends a Windows <b>WM_TCARD</b> message to the calling program to invoke a training card topic or to perform some other action.</p>

<p>Training cards are help topics that interact with the calling program by sending the appropriate message parameters via <b>WM_TCARD</b> in response to a user action, such as clicking a button within the help window. The calling program then handles the message and responds by performing a specific  action. The action can be anything from calling an HTML Help API function to opening an application dialog box.</p>

<p>Typical uses of training cards include guiding users through the steps of a certain task or a troubleshooting process.</p>

<p>This command can be used only with a compiled help (.chm) file.</p>

<h2>Syntax</h2>

<p><pre><code>
&lt;PARAM  name="Command" value="TCard"&gt;
<br>&lt;PARAM  name="Item1"   value="<i>wPARAM</i>, <i>lPARAM</i>"&gt;
<br>[&lt;PARAM name="Button"  value="[Text: <i>Button text</i>|Bitmap: <i>Bitmap file path</i>|Icon:<i>Icon file path</i>]"&gt;]
<br>[&lt;PARAM name="Text"    value="Text: <i>Link text</i>"&gt;]
<br>[&lt;PARAM name="Font"    value="<i><i>Facename[, point size[, charset[, color[, PLAIN BOLD ITALIC UNDERLINE]]]]</i></i>"&gt;]
</pre></code></p>

<br>
<table border=1 cellpadding=0 cellspacing=0 width=100%>
<tr valign=top>
<th width=25%>
<b>Property</b>
</th>
<th>
<b>Description</b>
</th>
</tr>

<tr valign=top>
<td>
<a href="ocx_pbutton.htm">Button</a>
</td>
<td>
Specifies the button style. Optional.</td>
</tr>

<tr valign=top>
<td>
<a href="ocx_pcommand.htm">Command</a>
<td>
Calls the <b>TCard</b> command.
</td>
</tr>

<tr valign=top>
<td>
<a href="ocx_pfont.htm">Font</a>
</td>

<td>
Specifies the font attributes. Optional.
</td>
</tr>

<tr valign=top>
<td>
<a href="ocx_pitem.htm">Item1</a>
<td>
Specifies the <i>wPARAM</i> and the <i>lPARAM</i> parameter values to pass to the <b>WM_TCARD</b> message.

<p><i>wPARAM</i> usually identifies a user action; this value must be numeric.</p>

<p><i>lPARAM</i> may contain additional data, depending on the value of <i>wPARAM</i>; this value may be numeric or string.</p>
</td>
</tr>

<tr valign=top>
<td>
<a href="ocx_ptext.htm">Text</a>
</td>

<td>
Specifies the link text. Optional.
</td>
</tr>
</table>

<h2>Example</h2>

<p><pre><code>
&lt;OBJECT
<br>  id=training
<br>  type=&quot;application/x-oleobject&quot;
<br>  classid=&quot;clsid:adb880a6-d8ff-11cf-9377-00aa003b7a11&quot;
<br>  codebase=&quot;HHCTRL.ocx#Version=4,72,8252,0&quot;
<br>  width=100
<br>  height=100
<br>&gt;
<br>  &lt;PARAM name=&quot;Command&quot; value=&quot;TCard&quot;&gt;
<br>  &lt;PARAM name=&quot;Button&quot; value=&quot;Text: This is a training card&quot;&gt;
<br>  &lt;PARAM name=&quot;Item1&quot; value=&quot;5555, MyText&quot;&gt;
&lt;/OBJECT&gt;
</pre></code></p>

<!--h2>Sample TCard command</h2>
<p>Postponed until next release.</p-->


<h2>Comments</h2>
<ul>
<li>The <b>TCard</b> command accepts both numeric and string arguments. </li> 

<li>To call the <b>TCard</b> command multiple times using a scripting language, use the <a href="ocx_mtcard.htm">TCard method</a>.</li>

<li>To implement training card topics, code must be added to the calling program to handle <b>WM_TCARD</b> messages.</li>
</ul>

<br>
<table border="0" cellpadding="0" cellspacing="4">
<tr>
<td valign="top"><a href="ocx_commands.htm"><img src="proced.gif" alt="link to overview topic" border="0"></a>
</td>
<td><a href="ocx_commands.htm">About commands</A>
</td>
</tr>

<tr>
<td>&nbsp;</td>
</tr>
</table>

</BODY>
</HTML>
